<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>东邻商家后台</title>
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no">
    <link href="assets/css/font-awesome-4.6.3/css/font-awesome.min.css" type="text/css" rel="stylesheet" />
    <link href="assets/css/pe-icon-7-stroke/css/pe-icon-7-stroke.css" type="text/css" rel="stylesheet" />
    <link href="assets/css/pe-icon-7-stroke/css/helper.css" type="text/css" rel="stylesheet" />
    <link href="http://v4.ismartjs.com/dist/css/animate.css" type="text/css" rel="stylesheet" />
    <link href="http://v4.ismartjs.com/dist/css/bootstrap.min.css" type="text/css" rel="stylesheet" />
    <link href="http://v4.ismartjs.com/dist/css/ismart.min.css" type="text/css" rel="stylesheet" />
    <link href="http://v4.ismartjs.com/css/animate.css" type="text/css" rel="stylesheet" />
    <link href="http://v4.ismartjs.com/css/spinkit.css" type="text/css" rel="stylesheet" />
    <link href="http://v4.ismartjs.com/css/bootstrap.min.css" type="text/css" rel="stylesheet" />
    <link href="http://v4.ismartjs.com/less/layout.css" type="text/css" rel="stylesheet" />
    <link href="http://v4.ismartjs.com/less/keyframes.css" type="text/css" rel="stylesheet" />
    <link href="http://v4.ismartjs.com/less/animate.css" type="text/css" rel="stylesheet" />
    <link href="http://v4.ismartjs.com/less/loading.css" type="text/css" rel="stylesheet" />
    <link href="http://v4.ismartjs.com/less/buttons.css" type="text/css" rel="stylesheet" />
    <link href="http://v4.ismartjs.com/less/labels.css" type="text/css" rel="stylesheet" />
    <link href="http://v4.ismartjs.com/less/panels.css" type="text/css" rel="stylesheet" />
    <link href="http://v4.ismartjs.com/less/modals.css" type="text/css" rel="stylesheet" />
    <link href="http://v4.ismartjs.com/less/table.css" type="text/css" rel="stylesheet" />
    <link href="http://v4.ismartjs.com/less/progresses.css" type="text/css" rel="stylesheet" />
    <link href="http://v4.ismartjs.com/less/normalize.css" type="text/css" rel="stylesheet" />
    <link href="http://v4.ismartjs.com/less/type.css" type="text/css" rel="stylesheet" />
    <link href="http://v4.ismartjs.com/less/component-animations.css" type="text/css" rel="stylesheet" />
    <link href="http://v4.ismartjs.com/less/utilities.css" type="text/css" rel="stylesheet" />
    <link href="http://v4.ismartjs.com/less/forms.css" type="text/css" rel="stylesheet" />
    <link href="http://v4.ismartjs.com/less/well.css" type="text/css" rel="stylesheet" />
    <link href="http://v4.ismartjs.com/less/ui.contextmenu.css" type="text/css" rel="stylesheet" />
    <link href="http://v4.ismartjs.com/less/ui.toast.css" type="text/css" rel="stylesheet" />
    <link href="http://v4.ismartjs.com/less/ui.alert.css" type="text/css" rel="stylesheet" />
    <link href="http://v4.ismartjs.com/less/ui.confirm.css" type="text/css" rel="stylesheet" />
    <link href="http://v4.ismartjs.com/less/ui.form.validation.css" type="text/css" rel="stylesheet" />
    <link href="http://v4.ismartjs.com/less/view.timeline.css" type="text/css" rel="stylesheet" />
    <link href="http://v4.ismartjs.com/less/view.forum.css" type="text/css" rel="stylesheet" />
    <link href="http://v4.ismartjs.com/less/widget.tpl.css" type="text/css" rel="stylesheet" />
    <link href="http://v4.ismartjs.com/less/datetimepicker.css" type="text/css" rel="stylesheet" />
    <link href="http://v4.ismartjs.com/less/login.css" type="text/css" rel="stylesheet" />
    <script type="text/javascript" src="http://v4.ismartjs.com/js/3rd/jquery-1.12.2.min.js"></script>
    <script type="text/javascript" src="http://v4.ismartjs.com/js/3rd/jquery-ui-1.10.4.custom.min.js"></script>
    <script type="text/javascript" src="http://v4.ismartjs.com/js/3rd/bootstrap.js"></script>
    <script type="text/javascript" src="http://v4.ismartjs.com/js/bootstrap-plugins/inputmask.js"></script>
    <script type="text/javascript" src="http://v4.ismartjs.com/js/bootstrap-plugins/cookie.js"></script>
    <script type="text/javascript" src="http://v4.ismartjs.com/js/bootstrap-plugins/input-select.js"></script>
    <script type="text/javascript" src="http://v4.ismartjs.com/js/3rd/bootstrap-datetimepicker.min.js"></script>
    <script type="text/javascript" src="http://v4.ismartjs.com/js/3rd/bootstrap-datetimepicker.zh-CN.js"></script>
    <script type="text/javascript" src="http://v4.ismartjs.com/js/3rd/jquery-dateFormat.min.js"></script>
    <script type="text/javascript" src="http://v4.ismartjs.com/js/3rd/echarts.min.js"></script>
    <script type="text/javascript" src="http://v4.ismartjs.com/js/3rd/jquery.peity.min.js"></script>
    <script type="text/javascript" src="http://v4.ismartjs.com/js/3rd/flot/jquery.flot.min.js"></script>
    <script type="text/javascript" src="http://v4.ismartjs.com/js/3rd/flot/jquery.flot.pie.min.js"></script>
    <script type="text/javascript" src="http://v4.ismartjs.com/js/3rd/flot/jquery.flot.spline.js"></script>
    <script type="text/javascript" src="http://v4.ismartjs.com/js/3rd/flot/jquery.flot.resize.min.js"></script>
    <script type="text/javascript" src="http://v4.ismartjs.com/js/3rd/ueditor/ueditor.config.js"></script>
    <script type="text/javascript" src="http://v4.ismartjs.com/js/3rd/ueditor/ueditor.all.js"> </script>
    <script type="text/javascript" src="http://v4.ismartjs.com/js/3rd/ueditor/lang/zh-cn/zh-cn.js"></script>
    <script type="text/javascript" src="http://v4.ismartjs.com/js/3rd/jquery.cookie.js"></script>
    <script type="text/javascript" src="http://v4.ismartjs.com/js/src/smart.core.js"></script>
    <script type="text/javascript" src="http://v4.ismartjs.com/js/src/smart.ui.js"></script>
    <script type="text/javascript" src="http://v4.ismartjs.com/js/src/smart.template.js"></script>
    <script type="text/javascript" src="http://v4.ismartjs.com/js/src/widgets/window.js"></script>
    <script type="text/javascript" src="http://v4.ismartjs.com/js/src/widgets/tpl.js"></script>
    <script type="text/javascript" src="http://v4.ismartjs.com/js/src/widgets/datac.js"></script>
    <script type="text/javascript" src="http://v4.ismartjs.com/js/src/widgets/databind.js"></script>
    <script type="text/javascript" src="http://v4.ismartjs.com/js/src/widgets/nameDataAdapter.js"></script>
    <script type="text/javascript" src="http://v4.ismartjs.com/js/src/widgets/loop.js"></script>
    <script type="text/javascript" src="http://v4.ismartjs.com/js/src/widgets/check.js"></script>
    <script type="text/javascript" src="http://v4.ismartjs.com/js/src/widgets/event.js"></script>
    <script type="text/javascript" src="http://v4.ismartjs.com/js/src/plugins/alert.js"></script>
    <script type="text/javascript" src="http://v4.ismartjs.com/js/src/plugins/confirm.js"></script>
    <script type="text/javascript" src="http://v4.ismartjs.com/js/src/plugins/popup.open.js"></script>
    <script type="text/javascript" src="http://v4.ismartjs.com/js/src/plugins/upload.js"></script>
    <script type="text/javascript" src="http://v4.ismartjs.com/js/src/plugins/toast.js"></script>
    <script type="text/javascript" src="http://v4.ismartjs.com/js/src/plugins/cascade.js"></script>
    <script type="text/javascript" src="http://v4.ismartjs.com/js/src/plugins/timeout.js"></script>
    <script type="text/javascript" src="http://v4.ismartjs.com/js/src/widgets-ui/contextmenu.js"></script>
    <script type="text/javascript" src="http://v4.ismartjs.com/js/src/widgets-ui/pagination.js"></script>
    <script type="text/javascript" src="http://v4.ismartjs.com/js/src/widgets-ui/pager.js"></script>
    <script type="text/javascript" src="http://v4.ismartjs.com/js/src/widgets-ui/form.js"></script>
    <script type="text/javascript" src="http://v4.ismartjs.com/js/src/widgets-ui/select.js"></script>
    <script type="text/javascript" src="http://v4.ismartjs.com/js/src/widgets-ui/valid.js"></script>
    <script type="text/javascript" src="http://v4.ismartjs.com/js/src/widgets-ui/tooltip.js"></script>
    <script type="text/javascript" src="http://v4.ismartjs.com/js/src/widgets-ui/popover.js"></script>
    <script type="text/javascript" src="http://v4.ismartjs.com/js/src/widgets-ui/datetimepicker.js"></script>
    <script type="text/javascript" src="http://v4.ismartjs.com/js/src/widgets-ui/affix.js"></script>
    <script type="text/javascript" src="assets/js/CLodopFuncs.js"></script>
    <script type="text/javascript" src="assets/js/utils.js"></script>

    <script type="text/javascript">
        $.ajaxSetup({
            traditional: true
        })
        $(function () {
            var layoutArgs = {config: {
                    /**
                     * 菜单的url
                     * */
                    menuUrl: "/api/menu",
                    asideTopUrl: "asideTop.html",
                    headerUrl: "header.html"
                }};
            Smart.UI.booting($("#root"), {
                /**
                 * 用于定义交互的模板，如弹出框，通知，警告框，确认框等等
                 * */
                uiTemplateUrl: "ui-template.html"
            }).done(function($root){
                $root.get("/api/login/check").done(function(rs){
                    if(rs.authenticated){
                        window.APP_CONTEXT = rs;
                        $root.load("layout-spring.html", layoutArgs);
                    } else {
                        $root.load("login.html");
                        $root.node.on("login:success", function (e, status) {
                            if (status) {
                                window.logined = status;
                                $root.load("layout-spring.html", layoutArgs);
                            }
                        });
                    }
                })

            })
        });
    </script>
</head>
<body>
<div id="root" s="window"></div>
</body>
</html>